﻿using System;

namespace ConsoleApp5
{
    class Program
    {
        static void Main(string[] args)
        {
            int[] a = new int[99];
            for(int i = 0; i < 98; i++)
            {
                a[i] = i+2;
            }
            for(int k = 2; k < 98; k++)
            {
                for (int j = 0; j < 98; j++)
                {
                    if (a[j]!=1&&a[j] % k == 0 && a[j] != k)
                        a[j] = 1;
                }
            }
            for(int l = 0; l < 98; l++)
            {
                if (a[l] != 1)
                    Console.Write(a[l] + " ");
            }
            Console.ReadKey();
        }
    }
}
